﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using ISSMoviePlex.DAL.Models;

namespace ISSMoviePlex.BLL
{
    public class GoldStateBLL : MemberStateBLL
    {
        public GoldStateBLL() : base()
        {
            memberState = _memberStateRepository.GetMemberStateByName("Gold"); 
        }

        public override void Check(Member member)
        {
            if (member.MoneySpent >= memberState.Amount)
            {
                member.MemberStateId = new PlatinumStateBLL().GetMemberStateID();
            }
        }
    }
}
